/**
 * 清单中收费设置的api js
 */
import request from "@/utils/request";

/**
 * 初始化收费设置页面数据字典初始化
 */
export function initChargeSetSysdictData() {
  return request({
    url:
      process.env.VUE_APP_KSTB_ROUTE_PATH +
      "/yxpz/chargeSet/initChargeSetSysdictData",
    method: "post",
    headers: {
      "Content-Type": "application/json;charset=UTF-8"
    }
  });
}

/**
 * 保存清单收费设置数据
 * @param {*} data
 */
export function saveOrUpdate(data) {
  return request({
    url: process.env.VUE_APP_KSTB_ROUTE_PATH + "/yxpz/chargeSet/saveOrUpdate",
    method: "post",
    headers: {
      "Content-Type": "application/json;charset=UTF-8"
    },
    data: data
  });
}

/**
 * 根据hdlOid查询清单的收费设置数据
 * @param {*} hdlOid
 */
export function queryByHdlOid(hdlOid) {
  return request({
    url:
      process.env.VUE_APP_KSTB_ROUTE_PATH +
      `/yxpz/chargeSet/queryByHdlOid/${hdlOid}`,
    method: "post",
    headers: {
      "Content-Type": "application/json;charset=UTF-8"
    }
  });
}
